from rest_framework import serializers
from rest_framework.viewsets import ModelViewSet
from labor_price.models import Jurisdiction
class JurisdictionSerializer(serializers.ModelSerializer):
    class Meta:
        model=Jurisdiction
        fields='__all__'

class JurisdictionView(ModelViewSet):
    queryset = Jurisdiction.objects.all()  # 查询集
    serializer_class = JurisdictionSerializer  # 序列化器